/*
 * Selling Partner API for Orders
 * Use the Orders Selling Partner API to programmatically retrieve order information. With this API, you can develop fast, flexible, and custom applications to manage order synchronization, perform order research, and create demand-based decision support tools.   _Note:_ For the JP, AU, and SG marketplaces, the Orders API supports orders from 2016 onward. For all other marketplaces, the Orders API supports orders for the last two years (orders older than this don't show up in the response).
 *
 * OpenAPI spec version: v0
 *
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */

package software.amazon.spapi.models.orders.v0;

import com.google.gson.annotations.SerializedName;
import io.swagger.v3.oas.annotations.media.Schema;
import java.util.Objects;

/** Substitution options for an order item. */
@Schema(description = "Substitution options for an order item.")
public class SubstitutionOption {
    @SerializedName("ASIN")
    private String ASIN = null;

    @SerializedName("QuantityOrdered")
    private Integer quantityOrdered = null;

    @SerializedName("SellerSKU")
    private String sellerSKU = null;

    @SerializedName("Title")
    private String title = null;

    @SerializedName("Measurement")
    private Measurement measurement = null;

    public SubstitutionOption ASIN(String ASIN) {
        this.ASIN = ASIN;
        return this;
    }

    /**
     * The item&#x27;s Amazon Standard Identification Number (ASIN).
     *
     * @return ASIN
     */
    @Schema(description = "The item's Amazon Standard Identification Number (ASIN).")
    public String getASIN() {
        return ASIN;
    }

    public void setASIN(String ASIN) {
        this.ASIN = ASIN;
    }

    public SubstitutionOption quantityOrdered(Integer quantityOrdered) {
        this.quantityOrdered = quantityOrdered;
        return this;
    }

    /**
     * The number of items to be picked for this substitution option.
     *
     * @return quantityOrdered
     */
    @Schema(description = "The number of items to be picked for this substitution option. ")
    public Integer getQuantityOrdered() {
        return quantityOrdered;
    }

    public void setQuantityOrdered(Integer quantityOrdered) {
        this.quantityOrdered = quantityOrdered;
    }

    public SubstitutionOption sellerSKU(String sellerSKU) {
        this.sellerSKU = sellerSKU;
        return this;
    }

    /**
     * The item&#x27;s seller stock keeping unit (SKU).
     *
     * @return sellerSKU
     */
    @Schema(description = "The item's seller stock keeping unit (SKU).")
    public String getSellerSKU() {
        return sellerSKU;
    }

    public void setSellerSKU(String sellerSKU) {
        this.sellerSKU = sellerSKU;
    }

    public SubstitutionOption title(String title) {
        this.title = title;
        return this;
    }

    /**
     * The item&#x27;s title.
     *
     * @return title
     */
    @Schema(description = "The item's title.")
    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public SubstitutionOption measurement(Measurement measurement) {
        this.measurement = measurement;
        return this;
    }

    /**
     * Get measurement
     *
     * @return measurement
     */
    @Schema(description = "")
    public Measurement getMeasurement() {
        return measurement;
    }

    public void setMeasurement(Measurement measurement) {
        this.measurement = measurement;
    }

    @Override
    public boolean equals(java.lang.Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        SubstitutionOption substitutionOption = (SubstitutionOption) o;
        return Objects.equals(this.ASIN, substitutionOption.ASIN)
                && Objects.equals(this.quantityOrdered, substitutionOption.quantityOrdered)
                && Objects.equals(this.sellerSKU, substitutionOption.sellerSKU)
                && Objects.equals(this.title, substitutionOption.title)
                && Objects.equals(this.measurement, substitutionOption.measurement);
    }

    @Override
    public int hashCode() {
        return Objects.hash(ASIN, quantityOrdered, sellerSKU, title, measurement);
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("class SubstitutionOption {\n");

        sb.append("    ASIN: ").append(toIndentedString(ASIN)).append("\n");
        sb.append("    quantityOrdered: ")
                .append(toIndentedString(quantityOrdered))
                .append("\n");
        sb.append("    sellerSKU: ").append(toIndentedString(sellerSKU)).append("\n");
        sb.append("    title: ").append(toIndentedString(title)).append("\n");
        sb.append("    measurement: ").append(toIndentedString(measurement)).append("\n");
        sb.append("}");
        return sb.toString();
    }

    /** Convert the given object to string with each line indented by 4 spaces (except the first line). */
    private String toIndentedString(java.lang.Object o) {
        if (o == null) {
            return "null";
        }
        return o.toString().replace("\n", "\n    ");
    }
}
